package edu.zhuravlev.trainingbot.it;


import lombok.AccessLevel;
import lombok.NoArgsConstructor;
import org.telegram.telegrambots.meta.api.objects.Update;
import org.telegram.telegrambots.meta.api.objects.User;
import org.telegram.telegrambots.meta.api.objects.chat.Chat;
import org.telegram.telegrambots.meta.api.objects.message.Message;


@NoArgsConstructor(access = AccessLevel.PRIVATE)
public class BotTestUtils {

    public static final User TEST_USER = new User(123L, "TestUserName", false);

    public static final Long TEST_CHAT = 12353245431L;

    public static Update getTestUpdateWithMessage(String message) {
        Message teleMessage = new Message();
        Update update = new Update();

        teleMessage.setChat(new Chat(TEST_CHAT, "test"));
        teleMessage.setText(message);
        teleMessage.setFrom(TEST_USER);
        update.setMessage(teleMessage);

        return update;
    }
}
